
sudo apt-get install ros-$ROS_DISTRO-libuvc-ros libgoogle-glog-dev -y


cd ../
catkin_make -DCATKIN_WHITELIST_PACKAGES="astra_camera"

current_path=$(pwd)

env_var=$(grep -c "source $current_path/devel/setup.bash" ~/.bashrc)

echo $env_var

if  [ $env_var -eq 0 ]; then
    echo "source $current_path/devel/setup.bash" >> ~/.bashrc 
fi

rospack list

cd src/ros_astra_camera

sudo cp 56-orbbec-usb.rules /etc/udev/rules.d

echo "Restarting udev"
echo ""
sudo service udev reload
sudo service udev restart

sudo udevadm control --reload && sudo  udevadm trigger